package com.mycar2w.cloud.entity;

import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;

/**
 * created time 2017/4/1
 *
 * @author ljc
 * @version V1.0
 * 加速行驶
 */
@Entity
@Table(name = "car_test_accelerate", schema = "mycar2wnew", catalog = "")
public class CarTestAccelerate {
    private Long id;
    private String fengine;
    private String transmissionCase;
    private String driveSystem;
    private Long carId;

    @Id
    @Column(name = "id", nullable = false)
    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    @Basic
    @Column(name = "fengine", nullable = true)
    public String getFengine() {
        return fengine;
    }

    public void setFengine(String fengine) {
        this.fengine = fengine;
    }

    @Basic
    @Column(name = "transmission_case", nullable = true)
    public String getTransmissionCase() {
        return transmissionCase;
    }

    public void setTransmissionCase(String transmissionCase) {
        this.transmissionCase = transmissionCase;
    }

    @Basic
    @Column(name = "drive_system", nullable = true)
    public String getDriveSystem() {
        return driveSystem;
    }

    public void setDriveSystem(String driveSystem) {
        this.driveSystem = driveSystem;
    }

    @Basic
    @Column(name = "car_id", nullable = true)
    public Long getCarId() {
        return carId;
    }

    public void setCarId(Long carId) {
        this.carId = carId;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        CarTestAccelerate that = (CarTestAccelerate) o;

        if (id != null ? !id.equals(that.id) : that.id != null) return false;
        if (fengine != null ? !fengine.equals(that.fengine) : that.fengine != null) return false;
        if (transmissionCase != null ? !transmissionCase.equals(that.transmissionCase) : that.transmissionCase != null)
            return false;
        if (driveSystem != null ? !driveSystem.equals(that.driveSystem) : that.driveSystem != null) return false;
        if (carId != null ? !carId.equals(that.carId) : that.carId != null) return false;

        return true;
    }

    @Override
    public int hashCode() {
        int result = id != null ? id.hashCode() : 0;
        result = 31 * result + (fengine != null ? fengine.hashCode() : 0);
        result = 31 * result + (transmissionCase != null ? transmissionCase.hashCode() : 0);
        result = 31 * result + (driveSystem != null ? driveSystem.hashCode() : 0);
        result = 31 * result + (carId != null ? carId.hashCode() : 0);
        return result;
    }
}
